class Room:
    def __init__(self):
        self.index: int = 0
        self.first_room: bool = False
        self.leo_room: bool = False
        self.leo_pre_room: bool = False
        self.leo_pre_pre_room: bool = False
        self.boss_pre_room: bool = False
        self.boss_room: bool = False
    def is_confirm(self) -> bool:
        return self.first_room or self.leo_room or self.leo_pre_room or self.leo_pre_pre_room or self.boss_pre_room or self.boss_room


class RoomMG:
    def __init__(self):
        self.rooms: list[Room] = []

    def add(self):
        r = Room()
        if len(self.rooms) == 0:
            r.first_room = True
        self.rooms.append(r)

    def get_curr(self) -> Room:
        return self.rooms[len(self.rooms) - 1]

    def get_pre(self) -> Room:
        return self.rooms[len(self.rooms) - 2]

    def get_pre_pre(self) -> Room:
        return self.rooms[len(self.rooms) - 3]

    def room_clear(self):
        self.rooms.clear()


if __name__ == '__main__':
    rmg = RoomMG()
    rmg.add()
    c=rmg.get_curr()
    c.boss_room=True
    rmg.add()
    print(rmg.get_curr().is_confirm())
